Variable Api
Functions
Get all variables of one type. Note that findAll returns only text variables. Experimental: this API may change in a minor release.
Get the type of a variable. Experimental: this API may change in a minor release.
Get a typeface variable. Experimental: this API may change in a minor release.
Rename a variable of any type. The value and the type move to the new key. Every block property bound to the variable follows the new key and keeps its value. For a text variable, every {{key}} token in text blocks is rewritten too. Experimental: this API may change in a minor release.
Set a color variable. Creates the variable if no variable has this key. Every block property bound to the variable takes the new value. If a bound property rejects the value, the call throws its error, but the variable and the other bound properties change anyway. Experimental: this API may change in a minor release.
Set an image variable. Creates the variable if no variable has this key. Every block property bound to the variable takes the new URI. If a bound property rejects the value, the call throws its error, but the variable and the other bound properties change anyway. Experimental: this API may change in a minor release.
Set a number variable. Creates the variable if no variable has this key. Every block property bound to the variable takes the new value. If a bound property rejects the value, the call throws its error, but the variable and the other bound properties change anyway. Experimental: this API may change in a minor release.
Set a typeface variable. Creates the variable if no variable has this key. Every text block whose typeface is bound to the variable takes the new typeface over its whole text. Bold and italic text keeps its formatting where the typeface supports it. If a bound property rejects the value, the call throws its error, but the variable and the other bound properties change anyway. Experimental: this API may change in a minor release.